QT       += core gui widgets

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets

TARGET = ImageManagementPlugin
TEMPLATE = lib
# 输出到主程序的插件目录（根据调试/发布模式 + 32/64位架构区分路径）
contains(CONFIG, debug) {
    # 调试模式路径
    contains(QMAKE_HOST.arch, i386) {
        # 32位架构
        DESTDIR = ../build/debug/x86/plugins
    } else {
        # 64位架构（兼容x86_64/amd64等）
        DESTDIR = ../build/debug/x64/plugins
    }
} else {
    # 发布模式路径
    contains(QMAKE_HOST.arch, i386) {
        # 32位架构
        DESTDIR = ../build/release/x86/plugins
    } else {
        # 64位架构
        DESTDIR = ../build/release/x64/plugins
    }
}

SOURCES += ImagePreviewWidget.cpp \
           ImagePreprocessingSettings.cpp \
           ImageSaver.cpp \
           ImageLoader.cpp \
           ImageManagementPlugin.cpp \
           ImageCacheManager.cpp \
           PreviewItem.cpp \
           FileHandler.cpp \
           UndoRedoManager.cpp \
           ImageOperation.cpp

HEADERS += ImagePreviewWidget.h \
           ImageCacheItem.h \
           ImagePreprocessingSettings.h \
           ImageSaver.h \
           ImageLoader.h \
           ImageManagementPlugin.h \
           $$PWD/../MainFrame/CameraPluginInterface.h \
           ImageCacheManager.h \
           PreviewItem.h \
           FileHandler.h \
           UndoRedoManager.h \
           ImageOperation.h

FORMS += ImagePreviewWidget.ui \
         ImagePreprocessingSettings.ui \
         PreviewItem.ui

# 导入路径配置
INCLUDEPATH += ../MainFrame

# 添加libtiff依赖以支持TIF格式
#LIBS += -ltiff

RESOURCES += \
    icon.qrc
